{extends file="./main.tpl"}
{block name=body}
<br />
<form name="partyForm" action="party.php" method="post">
<table align="center" border=2>
	<tr>
    <td align="center" class="table1" colspan="6">Party</td>
  </tr>
  <tr>
    <th class="table2">Party Name</th>
    <td class="table2"><input type="text" name="partyName" id="partyName" autofocus required /></td>
    
    <th class="table2">Party Type</th>
    <td class="table2" colspan="3">
      <select name="SelectPartyType">
        <option>Select Party Type</option>
        <option value="Customer">Customer</option>
        <option value="Supplier">Supplier</option>
      </select>	
    </td>
  </tr>
  <tr>
    <th class="table2" align="left">Address1</th>
    <td class="table2"><textarea name="address" rows="5"></textarea></td>
    <th class="table2">Address2</th>
    <td class="table2" colspan="3"><textarea name="address2" rows="5"></textarea></td>
  </tr>
  <tr>
    <th class="table2" align="left">City1</th>
    <td class="table2"><input type="text" name="city" id="city"></td>
    <th class="table2" align="left">City2</th>
    <td class="table2"><input type="text" name="city2" id="city2"></td>
    <td class="table2" colspan="2"></td>
  </tr>
  <tr>
    <th class="table2" align="left">Contact 1</th>
    <td class="table2" colspan="6"><input type="text" name="contact1" id="contact1"></td>
    
  </tr>
  <tr>
    <th class="table2" align="left">Contact 2</th>
    <td class="table2"><input type="text" name="contact2" id="contact2"></td>
    <th class="table2" align="left">Contact 3</th>
    <td class="table2"><input type="text" name="contact3" id="contact3"></td>
    <th class="table2" align="left">Contact 4</th>
    <td class="table2"><input type="text" name="contact4" id="contact4"></td>
  </tr>
  <tr>
    <td align="center" class="table1" colspan="6">Suppiler</td>
  </tr>
  <tr>
    <th class="table2" align="left">Email 1</th>
    <td class="table2"><input type="text" name="email" id="email"></td>
    <th class="table2" align="left">Email 2</th>
    <td class="table2" colspan=""><input type="text" name="email2" id="email2"></td>
    <th class="table2" align="left">Assistant</th>
    <td class="table2" colspan=""><input type="text" name="assistant" id="assistant"></td>
  </tr>
  <tr>
    <th class="table2" align="left">Web</th>
    <td class="table2" colspan="3"><input type="text" name="web" id="web"></td>
    <th class="table2" align="left">Assistance No</th>
    <td class="table2" colspan=""><input type="text" name="assistantNo" id="assistantNo"></td>
  </tr>
  <tr>
    <th class="table2" align="left">Fax1</th>
    <td class="table2" ><input type="text" name="fax1" id="fax1"></td>
    <th class="table2" align="left">Fax2</th>
    <td class="table2" colspan=""><input type="text" name="fax2" id="fax2"></td>
    <th class="table2" align="left">Assistance Address</th>
    <td class="table2" colspan=""><textarea rows="4" cols="50" name="assistantAdd"></textarea></td>
    
  </tr>
  <tr>
  	<td colspan="6" align="center" class="table1"><input type="submit" name="submitBtn" value="Submit" class="button" /></td>
  </tr>
  
</table>
</form>
<br /><br /><br />

<table align="center" border=2>
  <tr>
  	<th class="table1" NOWRAP>Action</th>
    <th class="table1" NOWRAP>Party Name</th>
    <th class="table1" NOWRAP>Party Type</th>
    <th class="table1" NOWRAP>Address</th>
    <th class="table1" NOWRAP>Address2</th>
    <th class="table1" NOWRAP>City</th>
    <th class="table1" NOWRAP>City2</th>
    <th class="table1" NOWRAP>Contact 1</th>
    <th class="table1" NOWRAP>Contact 2</th>
    <th class="table1" NOWRAP>Contact 3</th>
    <th class="table1" NOWRAP>Contact 4</th>
    <th class="table1" NOWRAP>Email 1</th>
    <th class="table1" NOWRAP>Email 2</th>
    <th class="table1" NOWRAP>Web</th>
    <th class="table1" NOWRAP>Fax 1</th>
    <th class="table1" NOWRAP>Fax 2</th>
    <th class="table1" NOWRAP>Assistant</th>
    <th class="table1" NOWRAP>Assistant No</th>
    <th class="table1" NOWRAP>Assistant Add</th>
  </tr>
  {section name="pty" loop=$partyArray}
  <tr>
  	<td class="table2"><a href="partyDelete.php?partyId={$partyArray[pty].partyId}" onclick="return confirm('Sure to Delete?');"class="link"><img src="./images/deleteIco.png"></a></td>
    <td class="table2">{$partyArray[pty].partyName}</td>
    <td class="table2">{$partyArray[pty].partyType}</td>
    <td class="table2">{$partyArray[pty].address}</td>
    <td class="table2">{$partyArray[pty].address2}</td>
    <td class="table2">{$partyArray[pty].city}</td>
    <td class="table2">{$partyArray[pty].city2}</td>
    <td class="table2">{$partyArray[pty].contact1}</td>
    <td class="table2">{$partyArray[pty].contact2}</td>
    <td class="table2">{$partyArray[pty].contact3}</td>
    <td class="table2">{$partyArray[pty].contact4}</td>
    <td class="table2">{$partyArray[pty].email}</td>
    <td class="table2">{$partyArray[pty].email2}</td>
    <td class="table2">{$partyArray[pty].web}</td>
    <td class="table2">{$partyArray[pty].fax1}</td>
    <td class="table2">{$partyArray[pty].fax2}</td>
    <td class="table2">{$partyArray[pty].assistant}</td>
    <td class="table2">{$partyArray[pty].assistantNo}</td>
    <td class="table2">{$partyArray[pty].assistantAdd}</td>
  </tr>
  {/section}
</table>
{/block}
